var baseUrl = "http://qlapi.sylu.edu.cn/mock/67";
function send_post() 
{
  var der = null;
  try 
  {
    der = new XMLHttpRequest();
  } 
  catch (error) 
  {
    der = new ActiveXObject("Microsoft.XMLHTTP");
  }
  der.open("post", `${baseUrl}/test`, true);
  der.setRequestHeader("content-type", "application/x-www-form-urlencoded");
  var x_value='username=${username}&age=${age}';
  der.send("x_value");
  der.onreadystatechange = function () 
  {
    if (der.readyState == 4) 
    {
      if (der.status == 200) 
      {
        const seg = der.responseText;
        let username=test.getElementById('username').value;
        let age=test.getElementById('age').value;
        
        console.log(seg);
      } 
      else 
      {
        alert("Error:" + xhr.status);
      }
    }
  }
}